﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using _测试1.Common;
using _测试1.Models;
using EF测试DbSet.Models;
using EF测试DbSet.Models.Entites;

namespace _测试1
{
    class Program
    {
        static void Main(string[] args)
        {

            #region 
            ////PersonInfo person = new PersonInfo();
            ////person.Id = 1;
            ////person.Birthday = DateTime.Now.AddYears(-33);
            ////person.Name = "张三";
            ////person.Sex = "男";
            ////person.Comm = new Commons
            ////{
            ////    CreateBy = "System",
            ////    CreateTime = DateTime.Now,
            ////    IsDel = 0,
            ////    DeleteBy = null,
            ////    DeleteTime = null
            ////};


            ////PropertyInfo[] propertys = person.GetType().GetProperties();
            ////PropertyInfo infoComm = person.GetType().GetProperty("Comm");
            ////Commons comm = person.GetType().GetProperty("Comm").GetValue(person) as Commons;

            ////comm.IsDel = 1;


            ////PersonInfo p2 = person;

            //Random rd1 = new Random();

            //int value1 = rd1.Next(1, 99);

            //Thread.Sleep(2000);

            //Random rd2 = new Random();

            //int value2 = rd2.Next(1, 99);

            //Console.WriteLine("{0},{1}", value1, value2);


            //Random rd3 = new Random();
            //Random rd4 = new Random();

            //Console.WriteLine("{0},{1}",rd3.Next(100,999),rd4.Next(100,999));



            //Console.ReadKey(); 
            #endregion

            using (var db = new BaseContext())
            {
                var data = db.Set<BaseUser>().Where(x => x.Id == 1).ToList();
            }

        }
    }
}
